﻿#if UNITY_EDITOR
using System;
using System.Collections.Generic;
using Ease.EaseNode.Runtime;

namespace Ease.EaseMission.Runtime
{
    public partial class MissionDataSo
    {
        private CommonNodeDataManager<MissionStage> _helper;

        public INodeDataManager NodeDataManager
        {
            get
            {
                if (_helper == null)
                {
                    _helper = new CommonNodeDataManager<MissionStage>(datas, new List<Type> { typeof(MissionStage) });
                    _helper.OnDataCreateEvent += (a) => { a.Id = datas.Count; };
                }

                return _helper;
            }
        }
    }
}
#endif